#!/usr/bin/env python
# -*- coding: utf-8 -*-

from documents.models import Item
from django.db import models

class Link(models.Model):
    """        
    Model for a Link - belonging to a certain Item
    """
    
    url = models.URLField(max_length = 800)
    
    internal = models.BooleanField()
    
    item = models.OneToOneField(Item)
    
    def __unicode__(self):
        return self.item.document.name + " " + self.item.user.username
    

